







OrderedSet<(Of <T>)> Members |
See Also Methods Properties Constructors Explicit Interface Implementations |
![]() ![]() |
[This topic is pre-release documentation and is subject to change in future releases. Blank topics are included as placeholders.]
Syntax
C# |
---|
[SerializableAttribute] public class OrderedSet<T> |
Visual Basic (Declaration) |
---|
<SerializableAttribute> _ Public Class OrderedSet(Of T) |
Visual C++ |
---|
[SerializableAttribute] generic<typename T> public ref class OrderedSet |
Type Parameters
- T
The type exposes the following members.
Public Constructors
Name | Description | |
---|---|---|
![]() | OrderedSet<(Of <T>)>OrderedSet<(Of <T>)>New | Overloaded. |
Public Methods
Name | Description | |
---|---|---|
![]() | Add |
Must be overridden to allow adding items to this collection.
|
![]() | AddMany |
Adds all the items in collection to the set. If the set already contains an item equal to
one of the items in collection, that item will be replaced.
|
![]() | AsList |
Get a read-only list view of the items in this ordered set. The
items in the list are in sorted order, with the smallest item
at index 0. This view does not copy any data, and reflects any
changes to the underlying OrderedSet.
|
![]() | AsReadOnly |
Provides a read-only view of this collection. The returned ICollection<T> provides
a view of the collection that prevents modifications to the collection. Use the method to provide
access to the collection without allowing changes. Since the returned object is just a view,
changes to the collection will be reflected in the view.
(Inherited from CollectionBase<(Of <T>)>.) |
![]() | Clear |
Removes all items from the set.
(Overrides CollectionBase<(Of <T>)>..::Clear()().) |
![]() | Clone |
Makes a shallow clone of this set; i.e., if items of the
set are reference types, then they are not cloned. If T is a value type,
then each element is copied as if by simple assignment.
|
![]() | CloneContents |
Makes a deep clone of this set. A new set is created with a clone of
each element of this set, by calling ICloneable.Clone on each element. If T is
a value type, then each element is copied as if by simple assignment.
|
![]() | Contains |
Determines if the collection contains a particular item. This default implementation
iterates all of the items in the collection via GetEnumerator, testing each item
against item using IComparable<T>.Equals or
Object.Equals.
|
![]() | ConvertAll<(Of <TOutput>)> |
Convert this collection of items by applying a delegate to each item in the collection. The resulting enumeration
contains the result of applying converter to each item in this collection, in
order.
(Inherited from CollectionBase<(Of <T>)>.) |
![]() | CopyTo |
Copies all the items in the collection into an array. Implemented by
using the enumerator returned from GetEnumerator to get all the items
and copy them to the provided array.
(Inherited from CollectionBase<(Of <T>)>.) |
![]() | CountWhere |
Counts the number of items in the collection that satisfy the condition
defined by predicate.
(Inherited from CollectionBase<(Of <T>)>.) |
![]() | Difference |
Computes the difference of this set with another set. The difference of these two sets
is all items that appear in this set, but not in otherSet. A new set is
created with the difference of the sets and is returned. This set and the other set
are unchanged.
|
![]() | DifferenceWith |
Computes the difference of this set with another set. The difference of these two sets
is all items that appear in this set, but not in otherSet. This set receives
the difference of the two sets; the other set is unchanged.
|
![]() | Equals | (Inherited from Object.) |
![]() | Exists |
Determines if the collection contains any item that satisfies the condition
defined by predicate.
(Inherited from CollectionBase<(Of <T>)>.) |
![]() | FindAll |
Enumerates the items in the collection that satisfy the condition defined
by predicate.
(Inherited from CollectionBase<(Of <T>)>.) |
![]() | ForEach |
Performs the specified action on each item in this collection.
(Inherited from CollectionBase<(Of <T>)>.) |
![]() | GetEnumerator |
Returns an enumerator that enumerates all the items in the set.
The items are enumerated in sorted order.
(Overrides CollectionBase<(Of <T>)>..::GetEnumerator()().) |
![]() | GetFirst |
Returns the first item in the set: the item
that would appear first if the set was enumerated. This is also
the smallest item in the set.
|
![]() | GetHashCode | Serves as a hash function for a particular type. GetHashCode()() is suitable for use in hashing algorithms and data structures like a hash table. (Inherited from Object.) |
![]() | GetLast |
Returns the lastl item in the set: the item
that would appear last if the set was enumerated. This is also the
largest item in the set.
|
![]() | GetType | Gets the Type of the current instance. (Inherited from Object.) |
![]() | IndexOf |
Get the index of the given item in the sorted order. The smallest item has index 0,
the next smallest item has index 1, and the largest item has index Count-1.
|
![]() | Intersection |
Computes the intersection of this set with another set. The intersection of two sets
is all items that appear in both of the sets. A new set is
created with the intersection of the sets and is returned. This set and the other set
are unchanged.
|
![]() | IntersectionWith |
Computes the intersection of this set with another set. The intersection of two sets
is all items that appear in both of the sets. This set receives
the intersection of the two sets, the other set is unchanged.
|
![]() | IsDisjointFrom |
Determines if this set is disjoint from another set. Two sets are disjoint
if no item from one set is equal to any item in the other set.
|
![]() | IsEqualTo |
Determines if this set is equal to another set. This set is equal to
otherSet if they contain the same items.
|
![]() | IsProperSubsetOf |
Determines if this set is a proper subset of another set. Neither set is modified.
This set is a subset of otherSet if every element in this set
is also in otherSet. Additionally, this set must have strictly
fewer items than otherSet.
|
![]() | IsProperSupersetOf |
Determines if this set is a proper superset of another set. Neither set is modified.
This set is a proper superset of otherSet if every element in
otherSet is also in this set.
Additionally, this set must have strictly more items than otherSet.
|
![]() | IsSubsetOf |
Determines if this set is a subset of another set. Neither set is modified.
This set is a subset of otherSet if every element in this set
is also in otherSet.
|
![]() | IsSupersetOf |
Determines if this set is a superset of another set. Neither set is modified.
This set is a superset of otherSet if every element in
otherSet is also in this set.
|
![]() | Range |
Returns a View collection that can be used for enumerating a range of the items in the set..
Only items that are greater than from and
less than to are included. The items are enumerated in sorted order.
Items equal to the end points of the range can be included or excluded depending on the
fromInclusive and toInclusive parameters.
|
![]() | RangeFrom |
Returns a View collection that can be used for enumerating a range of the items in the set..
Only items that are greater than (and optionally, equal to) from are included.
The items are enumerated in sorted order. Items equal to from can be included
or excluded depending on the fromInclusive parameter.
|
![]() | RangeTo |
Returns a View collection that can be used for enumerating a range of the items in the set..
Only items that are less than (and optionally, equal to) to are included.
The items are enumerated in sorted order. Items equal to to can be included
or excluded depending on the toInclusive parameter.
|
![]() | Remove |
Must be overridden to allow removing items from this collection.
|
![]() | RemoveAll |
Removes all the items in the collection that satisfy the condition
defined by predicate.
(Inherited from CollectionBase<(Of <T>)>.) |
![]() | RemoveFirst |
Removes the first item in the set. This is also the smallest item in the set.
|
![]() | RemoveLast |
Removes the last item in the set. This is also the largest item in the set.
|
![]() | RemoveMany |
Removes all the items in collection from the set. Items
not present in the set are ignored.
|
![]() | Reversed |
Returns a View collection that can be used for enumerating the items in the set in
reversed order.
|
![]() | SymmetricDifference |
Computes the symmetric difference of this set with another set. The symmetric difference of two sets
is all items that appear in either of the sets, but not both. A new set is
created with the symmetric difference of the sets and is returned. This set and the other set
are unchanged.
|
![]() | SymmetricDifferenceWith |
Computes the symmetric difference of this set with another set. The symmetric difference of two sets
is all items that appear in either of the sets, but not both. This set receives
the symmetric difference of the two sets; the other set is unchanged.
|
![]() | ToArray |
Creates an array of the correct size, and copies all the items in the
collection into the array, by calling CopyTo.
(Inherited from CollectionBase<(Of <T>)>.) |
![]() | ToString |
Shows the string representation of the collection. The string representation contains
a list of the items in the collection. Contained collections (except string) are expanded
recursively.
(Inherited from CollectionBase<(Of <T>)>.) |
![]() | TrueForAll |
Determines if all of the items in the collection satisfy the condition
defined by predicate.
(Inherited from CollectionBase<(Of <T>)>.) |
![]() | TryGetItem | Determines if this set contains an item equal to item, according to the comparison mechanism that was used when the set was created. The set is not changed. If the set does contain an item equal to item, then the item from the set is returned. |
![]() | Union |
Computes the union of this set with another set. The union of two sets
is all items that appear in either or both of the sets. A new set is
created with the union of the sets and is returned. This set and the other set
are unchanged.
|
![]() | UnionWith |
Computes the union of this set with another set. The union of two sets
is all items that appear in either or both of the sets. This set receives
the union of the two sets, the other set is unchanged.
|
Protected Methods
Name | Description | |
---|---|---|
![]() | Finalize | Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection. (Inherited from Object.) |
![]() | MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) |
Public Properties
Name | Description | |
---|---|---|
![]() | Comparer |
Returns the IComparer<T> used to compare items in this set.
|
![]() | Count |
Returns the number of items in the set.
(Overrides CollectionBase<(Of <T>)>..::Count.) |
![]() | Item |
Get the item by its index in the sorted order. The smallest item has index 0,
the next smallest item has index 1, and the largest item has index Count-1.
|
Explicit Interface Implementations
Name | Description | |
---|---|---|
![]() ![]() | ICollection<(Of <T>)>..::Add | |
![]() ![]() | ICollection<(Of <T>)>..::IsReadOnly | (Inherited from CollectionBase<(Of <T>)>.) |
![]() ![]() | ICollection..::CopyTo |
Copies all the items in the collection into an array. Implemented by
using the enumerator returned from GetEnumerator to get all the items
and copy them to the provided array.
(Inherited from CollectionBase<(Of <T>)>.) |
![]() ![]() | ICollection..::IsSynchronized |
Indicates whether the collection is synchronized.
(Inherited from CollectionBase<(Of <T>)>.) |
![]() ![]() | ICollection..::SyncRoot |
Indicates the synchronization object for this collection.
(Inherited from CollectionBase<(Of <T>)>.) |
![]() ![]() | IEnumerable..::GetEnumerator |
Provides an IEnumerator that can be used to iterate all the members of the
collection. This implementation uses the IEnumerator<T> that was overridden
by the derived classes to enumerate the members of the collection.
(Inherited from CollectionBase<(Of <T>)>.) |
![]() ![]() | ICloneable..::Clone |
Makes a shallow clone of this set; i.e., if items of the
set are reference types, then they are not cloned. If T is a value type,
then each element is copied as if by simple assignment.
|